package com.example.art.chapter1.test2

import android.content.Intent
import android.support.v7.app.AppCompatActivity
import android.os.Bundle
import android.view.View
import com.example.art.R
import kotlinx.android.synthetic.main.activity_intent_filter.*

/**
 * Created by 舍长
 * describe:进行Intent的隐式跳转
 */
class IntentFilterActivity : AppCompatActivity() {

    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContentView(R.layout.activity_intent_filter)
        btn_01.setOnClickListener(View.OnClickListener {
            val intent=Intent("com.example.art.chapter1.Action")
//            intent.addCategory("com.example.art.chapter1.Category1")
            startActivity(intent)
        })
    }
}
